#include "../socks4a.h"
int main(int argc, char *argv[])
{
  if (argc < 2) {
    fprintf(stderr, "Usage: %s <listen_port>\n", argv[0]);
  } else {

    uint16_t port = static_cast<uint16_t>(atoi(argv[1]));
    InetAddress listenAddr(port);

    EventLoop loop;
    Socks4a server(&loop, listenAddr);
    server.start();
    loop.loop();
  }
}
